Integrand size = 28, antiderivative size = 93 \[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=\frac {4 \sqrt [4]{-1} a^2 \arctan \left (\frac {(-1)^{3/4} \sqrt {d \tan (e+f x)}}{\sqrt {d}}\right )}{d^{5/2} f}-\frac {2 a^2}{3 d f (d \tan (e+f x))^{3/2}}-\frac {4 i a^2}{d^2 f \sqrt {d \tan (e+f x)}} \]
[Out]
Time = 0.19 (sec) , antiderivative size = 93, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.143, Rules used = {3623, 3610, 3614, 211} \[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=\frac {4 \sqrt [4]{-1} a^2 \arctan \left (\frac {(-1)^{3/4} \sqrt {d \tan (e+f x)}}{\sqrt {d}}\right )}{d^{5/2} f}-\frac {4 i a^2}{d^2 f \sqrt {d \tan (e+f x)}}-\frac {2 a^2}{3 d f (d \tan (e+f x))^{3/2}} \]
[In]
[Out]
Rule 211
Rule 3610
Rule 3614
Rule 3623
Rubi steps \begin{align*} \text {integral}& = -\frac {2 a^2}{3 d f (d \tan (e+f x))^{3/2}}+\frac {\int \frac {2 i a^2 d-2 a^2 d \tan (e+f x)}{(d \tan (e+f x))^{3/2}} \, dx}{d^2} \\ & = -\frac {2 a^2}{3 d f (d \tan (e+f x))^{3/2}}-\frac {4 i a^2}{d^2 f \sqrt {d \tan (e+f x)}}+\frac {\int \frac {-2 a^2 d^2-2 i a^2 d^2 \tan (e+f x)}{\sqrt {d \tan (e+f x)}} \, dx}{d^4} \\ & = -\frac {2 a^2}{3 d f (d \tan (e+f x))^{3/2}}-\frac {4 i a^2}{d^2 f \sqrt {d \tan (e+f x)}}+\frac {\left (8 a^4\right ) \text {Subst}\left (\int \frac {1}{-2 a^2 d^3+2 i a^2 d^2 x^2} \, dx,x,\sqrt {d \tan (e+f x)}\right )}{f} \\ & = \frac {4 \sqrt [4]{-1} a^2 \arctan \left (\frac {(-1)^{3/4} \sqrt {d \tan (e+f x)}}{\sqrt {d}}\right )}{d^{5/2} f}-\frac {2 a^2}{3 d f (d \tan (e+f x))^{3/2}}-\frac {4 i a^2}{d^2 f \sqrt {d \tan (e+f x)}} \\ \end{align*}
Time = 1.69 (sec) , antiderivative size = 83, normalized size of antiderivative = 0.89 \[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=\frac {(-6+6 i) \sqrt {2} a^2 \sqrt {d} \text {arctanh}\left (\frac {(1+i) \sqrt {d \tan (e+f x)}}{\sqrt {2} \sqrt {d}}\right )-\frac {2 a^2 d (6 i+\cot (e+f x))}{\sqrt {d \tan (e+f x)}}}{3 d^3 f} \]
[In]
[Out]
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 311 vs. \(2 (76 ) = 152\).
Time = 0.93 (sec) , antiderivative size = 312, normalized size of antiderivative = 3.35
method | result | size |
derivativedivides | \(\frac {2 a^{2} \left (\frac {-\frac {\left (d^{2}\right )^{\frac {1}{4}} \sqrt {2}\, \left (\ln \left (\frac {d \tan \left (f x +e \right )+\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}{d \tan \left (f x +e \right )-\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}\right )+2 \arctan \left (\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )-2 \arctan \left (-\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )\right )}{4 d}-\frac {i \sqrt {2}\, \left (\ln \left (\frac {d \tan \left (f x +e \right )-\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}{d \tan \left (f x +e \right )+\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}\right )+2 \arctan \left (\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )-2 \arctan \left (-\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )\right )}{4 \left (d^{2}\right )^{\frac {1}{4}}}}{d}-\frac {1}{3 \left (d \tan \left (f x +e \right )\right )^{\frac {3}{2}}}-\frac {2 i}{d \sqrt {d \tan \left (f x +e \right )}}\right )}{f d}\) | \(312\) |
default | \(\frac {2 a^{2} \left (\frac {-\frac {\left (d^{2}\right )^{\frac {1}{4}} \sqrt {2}\, \left (\ln \left (\frac {d \tan \left (f x +e \right )+\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}{d \tan \left (f x +e \right )-\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}\right )+2 \arctan \left (\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )-2 \arctan \left (-\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )\right )}{4 d}-\frac {i \sqrt {2}\, \left (\ln \left (\frac {d \tan \left (f x +e \right )-\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}{d \tan \left (f x +e \right )+\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}\right )+2 \arctan \left (\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )-2 \arctan \left (-\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )\right )}{4 \left (d^{2}\right )^{\frac {1}{4}}}}{d}-\frac {1}{3 \left (d \tan \left (f x +e \right )\right )^{\frac {3}{2}}}-\frac {2 i}{d \sqrt {d \tan \left (f x +e \right )}}\right )}{f d}\) | \(312\) |
parts | \(\frac {2 a^{2} d \left (-\frac {1}{3 d^{2} \left (d \tan \left (f x +e \right )\right )^{\frac {3}{2}}}-\frac {\left (d^{2}\right )^{\frac {1}{4}} \sqrt {2}\, \left (\ln \left (\frac {d \tan \left (f x +e \right )+\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}{d \tan \left (f x +e \right )-\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}\right )+2 \arctan \left (\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )-2 \arctan \left (-\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )\right )}{8 d^{4}}\right )}{f}+\frac {2 i a^{2} \left (-\frac {\sqrt {2}\, \left (\ln \left (\frac {d \tan \left (f x +e \right )-\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}{d \tan \left (f x +e \right )+\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}\right )+2 \arctan \left (\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )-2 \arctan \left (-\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )\right )}{4 d^{2} \left (d^{2}\right )^{\frac {1}{4}}}-\frac {2}{d^{2} \sqrt {d \tan \left (f x +e \right )}}\right )}{f}-\frac {a^{2} \left (d^{2}\right )^{\frac {1}{4}} \sqrt {2}\, \left (\ln \left (\frac {d \tan \left (f x +e \right )+\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}{d \tan \left (f x +e \right )-\left (d^{2}\right )^{\frac {1}{4}} \sqrt {d \tan \left (f x +e \right )}\, \sqrt {2}+\sqrt {d^{2}}}\right )+2 \arctan \left (\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )-2 \arctan \left (-\frac {\sqrt {2}\, \sqrt {d \tan \left (f x +e \right )}}{\left (d^{2}\right )^{\frac {1}{4}}}+1\right )\right )}{4 f \,d^{3}}\) | \(460\) |
[In]
[Out]
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 403 vs. \(2 (75) = 150\).
Time = 0.26 (sec) , antiderivative size = 403, normalized size of antiderivative = 4.33 \[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=-\frac {3 \, {\left (d^{3} f e^{\left (4 i \, f x + 4 i \, e\right )} - 2 \, d^{3} f e^{\left (2 i \, f x + 2 i \, e\right )} + d^{3} f\right )} \sqrt {-\frac {16 i \, a^{4}}{d^{5} f^{2}}} \log \left (\frac {{\left (-4 i \, a^{2} d e^{\left (2 i \, f x + 2 i \, e\right )} + {\left (d^{3} f e^{\left (2 i \, f x + 2 i \, e\right )} + d^{3} f\right )} \sqrt {\frac {-i \, d e^{\left (2 i \, f x + 2 i \, e\right )} + i \, d}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}} \sqrt {-\frac {16 i \, a^{4}}{d^{5} f^{2}}}\right )} e^{\left (-2 i \, f x - 2 i \, e\right )}}{2 \, a^{2}}\right ) - 3 \, {\left (d^{3} f e^{\left (4 i \, f x + 4 i \, e\right )} - 2 \, d^{3} f e^{\left (2 i \, f x + 2 i \, e\right )} + d^{3} f\right )} \sqrt {-\frac {16 i \, a^{4}}{d^{5} f^{2}}} \log \left (\frac {{\left (-4 i \, a^{2} d e^{\left (2 i \, f x + 2 i \, e\right )} - {\left (d^{3} f e^{\left (2 i \, f x + 2 i \, e\right )} + d^{3} f\right )} \sqrt {\frac {-i \, d e^{\left (2 i \, f x + 2 i \, e\right )} + i \, d}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}} \sqrt {-\frac {16 i \, a^{4}}{d^{5} f^{2}}}\right )} e^{\left (-2 i \, f x - 2 i \, e\right )}}{2 \, a^{2}}\right ) - 8 \, {\left (7 \, a^{2} e^{\left (4 i \, f x + 4 i \, e\right )} + 2 \, a^{2} e^{\left (2 i \, f x + 2 i \, e\right )} - 5 \, a^{2}\right )} \sqrt {\frac {-i \, d e^{\left (2 i \, f x + 2 i \, e\right )} + i \, d}{e^{\left (2 i \, f x + 2 i \, e\right )} + 1}}}{12 \, {\left (d^{3} f e^{\left (4 i \, f x + 4 i \, e\right )} - 2 \, d^{3} f e^{\left (2 i \, f x + 2 i \, e\right )} + d^{3} f\right )}} \]
[In]
[Out]
\[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=- a^{2} \left (\int \left (- \frac {1}{\left (d \tan {\left (e + f x \right )}\right )^{\frac {5}{2}}}\right )\, dx + \int \frac {\tan ^{2}{\left (e + f x \right )}}{\left (d \tan {\left (e + f x \right )}\right )^{\frac {5}{2}}}\, dx + \int \left (- \frac {2 i \tan {\left (e + f x \right )}}{\left (d \tan {\left (e + f x \right )}\right )^{\frac {5}{2}}}\right )\, dx\right ) \]
[In]
[Out]
Both result and optimal contain complex but leaf count of result is larger than twice the leaf count of optimal. 198 vs. \(2 (75) = 150\).
Time = 0.30 (sec) , antiderivative size = 198, normalized size of antiderivative = 2.13 \[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=\frac {\frac {3 \, a^{2} {\left (-\frac {\left (2 i + 2\right ) \, \sqrt {2} \arctan \left (\frac {\sqrt {2} {\left (\sqrt {2} \sqrt {d} + 2 \, \sqrt {d \tan \left (f x + e\right )}\right )}}{2 \, \sqrt {d}}\right )}{\sqrt {d}} - \frac {\left (2 i + 2\right ) \, \sqrt {2} \arctan \left (-\frac {\sqrt {2} {\left (\sqrt {2} \sqrt {d} - 2 \, \sqrt {d \tan \left (f x + e\right )}\right )}}{2 \, \sqrt {d}}\right )}{\sqrt {d}} + \frac {\left (i - 1\right ) \, \sqrt {2} \log \left (d \tan \left (f x + e\right ) + \sqrt {2} \sqrt {d \tan \left (f x + e\right )} \sqrt {d} + d\right )}{\sqrt {d}} - \frac {\left (i - 1\right ) \, \sqrt {2} \log \left (d \tan \left (f x + e\right ) - \sqrt {2} \sqrt {d \tan \left (f x + e\right )} \sqrt {d} + d\right )}{\sqrt {d}}\right )}}{d} - \frac {4 \, {\left (6 i \, a^{2} d \tan \left (f x + e\right ) + a^{2} d\right )}}{\left (d \tan \left (f x + e\right )\right )^{\frac {3}{2}} d}}{6 \, d f} \]
[In]
[Out]
none
Time = 0.80 (sec) , antiderivative size = 113, normalized size of antiderivative = 1.22 \[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=-\frac {4 i \, \sqrt {2} a^{2} \arctan \left (\frac {8 \, \sqrt {d^{2}} \sqrt {d \tan \left (f x + e\right )}}{4 i \, \sqrt {2} d^{\frac {3}{2}} + 4 \, \sqrt {2} \sqrt {d^{2}} \sqrt {d}}\right )}{d^{\frac {5}{2}} f {\left (\frac {i \, d}{\sqrt {d^{2}}} + 1\right )}} - \frac {2 \, {\left (6 i \, a^{2} d \tan \left (f x + e\right ) + a^{2} d\right )}}{3 \, \sqrt {d \tan \left (f x + e\right )} d^{3} f \tan \left (f x + e\right )} \]
[In]
[Out]
Time = 5.39 (sec) , antiderivative size = 80, normalized size of antiderivative = 0.86 \[ \int \frac {(a+i a \tan (e+f x))^2}{(d \tan (e+f x))^{5/2}} \, dx=-\frac {\frac {2\,a^2}{3\,d\,f}+\frac {a^2\,\mathrm {tan}\left (e+f\,x\right )\,4{}\mathrm {i}}{d\,f}}{{\left (d\,\mathrm {tan}\left (e+f\,x\right )\right )}^{3/2}}-\frac {\sqrt {4{}\mathrm {i}}\,a^2\,\mathrm {atan}\left (\frac {\sqrt {4{}\mathrm {i}}\,\sqrt {d\,\mathrm {tan}\left (e+f\,x\right )}}{2\,\sqrt {-d}}\right )\,2{}\mathrm {i}}{{\left (-d\right )}^{5/2}\,f} \]
[In]
[Out]